SOURCE
PRECISION 14
PROCS=0
INTEGER: NUMRECS,RETCODE
STRING: INFILE[16],OUTFILE[16],CTLSTMT[40]

CODE "XSORTBB.BIN"

'MAIN Program:
1 REM SAMPLE BETTER BASIC PROGRAM CALLING SORTRES
2 INFILE  = "SAMP.DAT"
3 OUTFILE = "SORTED.DAT"
4 CTLSTMT = "S(1,10,C,A)"
5 PRINT "CALLING OPT-TECH SORT ..."
6 CALL SORTBB(INFILE,OUTFILE,CTLSTMT,NUMRECS,RETCODE)
7 PRINT "BACK FROM OPT-TECH SORT"
8 PRINT "NUMBER OF RECORDS SORTED = ",NUMRECS
9 PRINT "SORT RETURN STATUS CODE = ",RETCODE

ENDFILE
